	$(function(){
        //按钮单击时执行
        $("#admin_notice_edit_do").click(function(){
			toastr.options = {
			  "closeButton": true,
			  "debug": false,
			  "progressBar": true,
			  "positionClass": "toast-bottom-full-width",
			  "onclick": null,
			  "showDuration": "400",
			  "hideDuration": "1000",
			  "timeOut": "7000",
			  "extendedTimeOut": "1000",
			  "showEasing": "swing",
			  "hideEasing": "linear",
			  "showMethod": "fadeIn",
			  "hideMethod": "fadeOut"
			}
			//输入验证
			if($("#notice_id").val() == ""){  
                toastr.warning("公告ID不能为空！");  
                $("#notice_id").focus();  
                return false;  
            }
			if($("#notice_title").val() == ""){  
                toastr.warning("公告标题不能为空！");  
                $("#notice_title").focus();  
                return false;  
            }  
           if($("#notice_body").val() == ""){  
                toastr.warning("公告内容不能为空！");  
                $("#notice_body").focus();  
                return false;  
            }  
			var notice_id = $('#notice_id').val();
			var notice_title = $('#notice_title').val();
			var notice_body = $('#notice_body').val();
            //Ajax调用处理
            var admin_notice_edit_do = $.ajax({
               type: "POST",
               url: "index.php?m=notice&c=notice_admin&a=admin_notice_edit_do",
               data: "notice_id="+notice_id+"&notice_title="+notice_title+"&notice_body="+notice_body,
               async: false
            }).responseText;
			if (admin_notice_edit_do == "1"){
				toastr.info("公告修改失败！");
			} else if (admin_notice_edit_do == "2") {
				toastr.success("公告修改成功！");
			} else {
				toastr.error("请勿提交非法数据！");
			}
         });		 
    });